#ifndef _GBL_TYPES_H_
#define _GBL_TYPES_H_

typedef unsigned char BOOL;
typedef unsigned char UINT8;
typedef unsigned short UINT16;
typedef unsigned long UINT32;

typedef char CHAR;
typedef signed char INT8;
typedef signed short INT16;
typedef signed long INT32;

/* Standard typedefs */
typedef unsigned char Bool; /* Boolean                        */

/* Standard typedefs - to retain compatibility with TDMA */
typedef UINT8 BYTE;                /* Unsigned 8-bit quantity        */
typedef UINT8 UBYTE;               /* Unsigned 8-bit quantity        */
typedef UINT16 UWORD;              /* Unsigned 16-bit quantity       */
typedef UINT16 WORD;               /* Unsigned 16-bit quantity       */
typedef INT16 SWORD;               /* Signed 16-bit quantity         */
typedef UINT32 DWORD;              /* Unsigned 32-bit quantity       */
typedef unsigned long long UINT64; /* Unsigned 64-bit quantity       */
typedef void *VOID_PTR;

#define CONST const

#ifndef TRUE
#define FALSE 0
#define TRUE 1
#endif /* TRUE */

/* Definition of NULL is required */
#ifndef NULL
#define NULL 0L
#endif /* NULL */

#ifndef VOID
#define VOID void
#endif

// arm compiler specific keyword
#define __align(x) __attribute__((aligned(x)))

/*
 * Structure returned by gettimeofday(2) system call,
 * and used in other calls.
 */
#ifndef _TIMEVAL_DEFINED
#define _TIMEVAL_DEFINED
struct timeval
{
    long tv_sec;  /* seconds */
    long tv_usec; /* and microseconds */
};
#endif

#endif /* _GBL_TYPES_H_ */
